home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Tech Arsenal 1
/
Tech Arsenal (Arsenal Computer).ISO
/
tek-04
/
bipl.zip
/
PROGS.ZIP
/
ADLFILTR.ICN
< prev
next >
Wrap
Text File
|
1992-09-28
|
1KB
|
55 lines
############################################################################
#
# File: adlfiltr.icn
#
# Subject: Program to filter address list entries
#
# Author: Ralph E. Griswold
#
# Date: September 2, 1991
#
###########################################################################
#
# This program filters address lists, allowing through only those entries
# with specified selectors.
#
# The options are:
#
# -s arg selects entries with characters in args (default is all)
# -x inverts the logic, selecting characters not in args
#
############################################################################
#
# See also: address.doc, adlcheck.icn, adlcount.icn, adllist.icn,
# adlsort,icn, labels.icn
#
# Links: adlutils, options
#
############################################################################
link adlutils, options
procedure main(args)
local selectors, add, opts
opts := options(args,"xs:")
selectors := cset(\opts["s"]) | &cset
if /opts["x"] then {
while add := nextadd() do
add.header ? {
move(1)
if upto(selectors) then writeadd(add)
}
}
else {
while add := nextadd() do
add.header ? {
move(1)
if not upto(selectors) then writeadd(add)
}
}
end